package com.birdy.service.impl;

import com.birdy.mapper.GoalMapper;
import com.birdy.service.IGoalService;
import com.birdy.vo.Goal;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author birdy
 * @date 2022/5/3 6:46 PM
 */
@Service
public class GoalServiceImpl implements IGoalService {
    @Autowired
    private GoalMapper goalMapper;

    @Override
    public void addGoal(Goal goal) {
        goalMapper.addGoal(goal);
    }

    @Override
    public List<Goal> getGoalByCreator(String creator) {
        return goalMapper.getGoalByCreator(creator);
    }

    @Override
    public void updateGoal(Goal goal) {
        goalMapper.updateGoal(goal);
    }
}
